import request from '@/utils/request'
// 查询用户个人信息
export function getArticleList(params) {
  return request({
    url: '/article/newList',
    method: 'get',
    data: params
  })
}

export function getMyArticleList(params) {
  return request({
    url: '/article/myList',
    method: 'get',
    data: params
  })
}


// 查询详细
export function getArticle(Id) {
  return request({
    url: '/Article/' + Id,
    method: 'get',
  })
}

// 新增
export function addArticle(data) {
  return request({
    url: '/Article/add',
    method: 'post',
    data: data,
  })
}

// 修改
export function updateArticle(data) {
  return request({
    url: '/Article/edit',
    method: 'put',
    data: data
  })
}

// 删除随笔
export function delArticle(id) {
  return request({
    url: '/Article/' + id,
    method: 'delete'
  })
}